816 research outputs found

    Evolutionary improvement of programs

    Get PDF
    Most applications of genetic programming (GP) involve the creation of an entirely new function, program or expression to solve a specific problem. In this paper, we propose a new approach that applies GP to improve existing software by optimizing its non-functional properties such as execution time, memory usage, or power consumption. In general, satisfying non-functional requirements is a difficult task and often achieved in part by optimizing compilers. However, modern compilers are in general not always able to produce semantically equivalent alternatives that optimize non-functional properties, even if such alternatives are known to exist: this is usually due to the limited local nature of such optimizations. In this paper, we discuss how best to combine and extend the existing evolutionary methods of GP, multiobjective optimization, and coevolution in order to improve existing software. Given as input the implementation of a function, we attempt to evolve a semantically equivalent version, in this case optimized to reduce execution time subject to a given probability distribution of inputs. We demonstrate that our framework is able to produce non-obvious optimizations that compilers are not yet able to generate on eight example functions. We employ a coevolved population of test cases to encourage the preservation of the function's semantics. We exploit the original program both through seeding of the population in order to focus the search, and as an oracle for testing purposes. As well as discussing the issues that arise when attempting to improve software, we employ rigorous experimental method to provide interesting and practical insights to suggest how to address these issues

    On how the ECT fuels the fossil fuel economy: Rockhopper v Italy as a case study

    Get PDF
    The central thesis of this article is that the Energy Charter Treaty can be deployed to expand the fossil fuel industry’s rights and contextually counter democratic forces that animate the ecological transition. More specifically, the article shows the entanglement between the suppression of ecological democracy and the expansion of fossil rights. To offer a more granular understanding of how the Energy Charter Treaty empowers the fossil industry, this article zooms in on the case of Rockhopper v Italy. The case was launched in 2017 by the UK company Rockhopper against the Italian Republic because the latter denied a production concession for offshore oil drilling off the coast of Italy. After a long process of resistance from local communities, in 2016, the Italian government adopted a law of general applicability banning offshore drilling within 12 nautical miles of the coast. Drawing on political theory, this article conceptualises people’s successful forms of resistance to the oil extractivist project as ecological democracy. By unpacking the main facts underpinning this case and the legal reasoning in the award, the article shows how the Rockhopper award has bestowed new property rights on the fossil fuel investor while contextually compressing democratic spaces vital for the ecological transition

    Food habits of largemouth bass, Micropterus salmoides (Lacepede) and spotted bass, Micropterus punctulatus (Rafinesque), from Beech Fork Reservoir, a new impoundment in Wayne and Cabell Counties, West Virginia

    Get PDF
    A study was undertaken to determine the food habits of two game fishes, the largemouth bass Micropterus salmoides (Lacepede) and the spotted bass M. punctulatus (Rafinesque) in Beech Fork Reservoir shortly after its impoundment. A total of 171 largemouth bass and 95 spotted bass were collected from July 1978, through June 1979, and their stomach contents analyzed. Largemouth bass fed primarily on fishes, particularly young-of-the-year bluegill. Aquatic and terrestrial invertebrates were also important food items, especially during the spring and fall . The dominant aquatic forms were chironomid larvae and pupae while the dominant terrestrial forms were adult dipterans. Spotted bass utilized aquatic and terrestrial invertebrates more than fishes as food. Chironomid larvae and pupae were the most important aquatic invertebrates consumed while adult dipterans and hymenopterans dominated the terrestrial food category. Entomostracans were eaten by some of the smaller spotted bass, but were not found in any of the largemouth bass. The majority of the forage fishes of spotted bass were unidentifiable. However, none of these fishes were soft-rayed, indicating that minnows were not an important food item. Soft-rayed fishes were also conspicuously absent from the diet of largemouth bass. Crayfish were consumed by both species of bass but, when compared with the other food groups, were of relatively minor importance

    Java Enterprise Edition Support in Search-Based JUnit Test Generation.

    Get PDF
    Many different techniques and tools for automated unit test generation target the Java programming languages due to its popularity. However, a lot of Java’s popularity is due to its usage to develop enterprise applications with frameworks such as Java Enterprise Edition (JEE) or Spring. These frameworks pose challenges to the automatic generation of JUnit tests. In particular, code units (“beans”) are handled by external web containers (e.g., WildFly and GlassFish). Without considering how web containers initialize these beans, automatically generated unit tests would not represent valid scenarios and would be of little use. For example, common issues of bean initialization are dependency injection, database connection, and JNDI bean lookup. In this paper, we extend the EvoSuite search-based JUnit test generation tool to provide initial support for JEE applications. Experiments on 247 classes (the JBoss EAP tutorial examples) reveal an increase in code coverage, and demonstrate that our techniques prevent the generation of useless tests (e.g., tests where dependencies are not injected)

    EvoSuite at the SBST 2016 Tool Competition

    Get PDF
    EvoSuite is a search-based tool that automatically generates unit tests for Java code. This paper summarizes the results and experiences of EvoSuite's participation at the fourth unit testing competition at SBST 2016, where Evo-Suite achieved the highest overall score

    Economical comparison of CHP systems for industrial user with large steam demand

    Get PDF
    In this paper cogeneration benefits applied to a user with a high steam demand are analyzed. The methodology for the feasibility study and the economical analysis of the investment is presented under the Italian legislative framework. The methodology is applied to an actual case and a detailed description and discussion of all data input is provided. Especially this last key point will be faced using starting data usually available in these kind of studies (i.e., not very detailed for thermal consumption). Finally a comparison of different CHP technologies and a sensitivity analysis is done

    Private API Access and Functional Mocking in Automated Unit Test Generation

    Get PDF
    Not all object oriented code is easily testable: Dependency objects might be difficult or even impossible to instantiate, and object-oriented encapsulation makes testing potentially simple code difficult if it cannot easily be accessed. When this happens, then developers can resort to mock objects that simulate the complex dependencies, or circumvent object-oriented encapsulation and access private APIs directly through the use of, for example, Java reflection. Can automated unit test generation benefit from these techniques as well? In this paper we investigate this question by extending the EvoSuite unit test generation tool with the ability to directly access private APIs and to create mock objects using the popular Mockito framework. However, care needs to be taken that this does not impact the usefulness of the generated tests: For example, a test accessing a private field could later fail if that field is renamed, even if that renaming is part of a semantics-preserving refactoring. Such a failure would not be revealing a true regression bug, but is a false positive, which wastes the developer's time for investigating and fixing the test. Our experiments on the SF110 and Defects4J benchmarks confirm the anticipated improvements in terms of code coverage and bug finding, but also confirm the existence of false positives. However, by ensuring the test generator only uses mocking and reflection if there is no other way to reach some part of the code, their number remains small

    Unit Test Generation During Software Development: EvoSuite Plugins for Maven, IntelliJ and Jenkins

    Get PDF
    Different techniques to automatically generate unit tests for object oriented classes have been proposed, but how to integrate these tools into the daily activities of software development is a little investigated question. In this paper, we report on our experience in supporting industrial partners in introducing the EVOSUITE automated JUnit test generation tool in their software development processes. The first step consisted of providing a plugin to the Apache Maven build infrastructure. The move from a research-oriented point-and-click tool to an automated step of the build process has implications on how developers interact with the tool and generated tests, and therefore, we produced a plugin for the popular IntelliJ Integrated Development Environment (IDE). As build automation is a core component of Continuous Integration (CI), we provide a further plugin to the Jenkins CI system, which allows developers to monitor the results of EVOSUITE and integrate generated tests in their source tree. In this paper, we discuss the resulting architecture of the plugins, and the challenges arising when building such plugins. Although the plugins described are targeted for the EVOSUITE tool, they can be adapted and their architecture can be reused for other test generation tools as well

    A Memetic Algorithm for whole test suite generation

    Get PDF
    The generation of unit-level test cases for structural code coverage is a task well-suited to Genetic Algorithms. Method call sequences must be created that construct objects, put them into the right state and then execute uncovered code. However, the generation of primitive values, such as integers and doubles, characters that appear in strings, and arrays of primitive values, are not so straightforward. Often, small local changes are required to drive the value toward the one needed to execute some target structure. However, global searches like Genetic Algorithms tend to make larger changes that are not concentrated on any particular aspect of a test case. In this paper, we extend the Genetic Algorithm behind the EvoSuiTE test generation tool into a Memetic Algorithm, by equipping it with several local search operators. These operators are designed to efficiently optimize primitive values and other aspects of a test suite that allow the search for test cases to function more effectively. We evaluate our operators using a rigorous experimental methodology on over 12,000 Java classes, comprising open source classes of various different kinds, including numerical applications and text processors. Our study shows that increases in branch coverage of up to 53% are possible for an individual class in practice
    corecore